package ventanas;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;

import javax.swing.WindowConstants;
import javax.swing.SwingUtilities;


/**
* This code was edited or generated using CloudGarden's Jigloo
* SWT/Swing GUI Builder, which is free for non-commercial
* use. If Jigloo is being used commercially (ie, by a corporation,
* company or business for any purpose whatever) then you
* should purchase a license for each developer using Jigloo.
* Please visit www.cloudgarden.com for details.
* Use of Jigloo implies acceptance of these licensing terms.
* A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
* THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
* LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
*/
public class VentanaAdministracionCentral extends javax.swing.JFrame {
	private JButton btnBuscarProd;
	private JButton btnOrdenCompra;

	/**
	* Auto-generated main method to display this JFrame
	*/
	public static void main(String[] args) {
		SwingUtilities.invokeLater(new Runnable() {
			public void run() {
				VentanaAdministracionCentral inst = new VentanaAdministracionCentral();
				inst.setLocationRelativeTo(null);
				inst.setVisible(true);
			}
		});
	}
	
	public VentanaAdministracionCentral() {
		super();
		initGUI();
	}
	
	private void initGUI() {
		try {
			setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
			getContentPane().setLayout(null);
			{
				btnBuscarProd = new JButton();
				getContentPane().add(btnBuscarProd);
				btnBuscarProd.setText("Buscar Producto");
				btnBuscarProd.setBounds(44, 35, 135, 30);
			}
			{
				btnOrdenCompra = new JButton();
				getContentPane().add(btnOrdenCompra);
				btnOrdenCompra.setText("Orden Compra");
				btnOrdenCompra.setBounds(44, 102, 135, 31);
			}
			pack();
			setSize(400, 300);
		} catch (Exception e) {
			e.printStackTrace();
		}
		
		btnBuscarProd.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent ae) {
				new VentanaBuscarProducto();
				setVisible(false);
			}
		});
		
		btnOrdenCompra.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent ae) {
				new VentanaGenerarOC();
				setVisible(false);
			}
		});
		
		
	}
	
}
